package com.ruoyi.ams.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.ams.domain.AmsAssetInventorySurplus;
import com.ruoyi.ams.mapper.AmsAssetInventorySurplusMapper;
import com.ruoyi.ams.service.IAmsAssetInventorySurplusService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 盘盈Service业务层处理
 * 
 * @author yfkj
 * @date 2022-05-16
 */
@Service
public class AmsAssetInventorySurplusServiceImpl extends ServiceImpl<AmsAssetInventorySurplusMapper, AmsAssetInventorySurplus>  implements IAmsAssetInventorySurplusService
{
    @Autowired
    private AmsAssetInventorySurplusMapper amsAssetInventorySurplusMapper;

    /**
     * 查询盘盈
     * 
     * @param inventorySurplusId 盘盈主键
     * @return 盘盈
     */
    @Override
    public AmsAssetInventorySurplus selectAmsAssetInventorySurplusByInventorySurplusId(Long inventorySurplusId)
    {
        return amsAssetInventorySurplusMapper.selectAmsAssetInventorySurplusByInventorySurplusId(inventorySurplusId);
    }

    /**
     * 查询盘盈列表
     * 
     * @param amsAssetInventorySurplus 盘盈
     * @return 盘盈
     */
    @Override
    public List<AmsAssetInventorySurplus> selectAmsAssetInventorySurplusList(AmsAssetInventorySurplus amsAssetInventorySurplus)
    {
        return amsAssetInventorySurplusMapper.selectAmsAssetInventorySurplusList(amsAssetInventorySurplus);
    }

    /**
     * 新增盘盈
     * 
     * @param amsAssetInventorySurplus 盘盈
     * @return 结果
     */
    @Override
    public int insertAmsAssetInventorySurplus(AmsAssetInventorySurplus amsAssetInventorySurplus)
    {
        return amsAssetInventorySurplusMapper.insertAmsAssetInventorySurplus(amsAssetInventorySurplus);
    }

    /**
     * 修改盘盈
     * 
     * @param amsAssetInventorySurplus 盘盈
     * @return 结果
     */
    @Override
    public int updateAmsAssetInventorySurplus(AmsAssetInventorySurplus amsAssetInventorySurplus)
    {
        return amsAssetInventorySurplusMapper.updateAmsAssetInventorySurplus(amsAssetInventorySurplus);
    }

    /**
     * 批量删除盘盈
     * 
     * @param inventorySurplusIds 需要删除的盘盈主键
     * @return 结果
     */
    @Override
    public int deleteAmsAssetInventorySurplusByInventorySurplusIds(Long[] inventorySurplusIds)
    {
        return amsAssetInventorySurplusMapper.deleteAmsAssetInventorySurplusByInventorySurplusIds(inventorySurplusIds);
    }

    /**
     * 删除盘盈信息
     * 
     * @param inventorySurplusId 盘盈主键
     * @return 结果
     */
    @Override
    public int deleteAmsAssetInventorySurplusByInventorySurplusId(Long inventorySurplusId)
    {
        return amsAssetInventorySurplusMapper.deleteAmsAssetInventorySurplusByInventorySurplusId(inventorySurplusId);
    }
}
